"""CreateUsersTable Migration."""

from masoniteorm.migrations import Migration


class CreateUsersTable(Migration):

    def up(self):
        """
               Run the migrations.
        """
        with create('users') as table:
            table.increments('id')
            table.string('username').unique().nullable()
            table.string('phone',11).unique()
            table.string('password_hash').nullable()
            table.timestamps()
            table.datetime('last_login_at').nullable()
            table.boolean('is_active').default(True)
    def down(self):
        # self.schema.drop('users')
        pass
